from selenium.webdriver.common.by import By

from base import Base
class Page(Base):
    def finds(self):
        loc=(By.XPATH,'//android.widget.TextView[@text="搜商品名称 作者 出版社 ISBN"]')
        ele=self.findele(loc)
        return ele

    def findss(self):
        loc=(By.CLASS_NAME,'android.widget.EditText')
        ele=self.findele(loc)
        return ele
    def sousuoanniu(self):
        loc=(By.ID,'com.kongfz.app:id/tvSearch')
        ele=self.findele(loc)
        return ele
    def banbenzaishou(self):
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="com.kongfz.app:id/tvHitLeft"]')
        ele=self.findele(loc)
        return ele
    def gouwuche(self):
        loc=(By.ANDROID_UIAUTOMATOR,'new UiSelector().text("").instance(0)')
        ele=self.findele_wait(loc)
        return ele

    def dingweishouye(self):
        a=68
        b=1214
        self.dianji(a,b)
        #首页滑动
    def shouyehua(self):
        a=359
        b=977
        c=359
        d=325
        self.hua(a,b,c,d)